package org.aristotle.demo.model.vo;

import com.alibaba.fastjson.annotation.JSONField;
import com.alibaba.fastjson.serializer.ToStringSerializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

@Data
@ApiModel("图书")
public class BookVO {

    @ApiModelProperty("图书id")
    @JSONField(name = "id", serializeUsing = ToStringSerializer.class)
    private java.lang.Long id;

    @ApiModelProperty("图书名")
    @JSONField(name = "title")
    private java.lang.String title;

    @ApiModelProperty("图书信息")
    @JSONField(name = "info")
    private java.lang.String info;

    @ApiModelProperty("创建时间")
    @JSONField(name = "createTime", format = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private java.util.Date createTime;

    @ApiModelProperty("修改时间")
    @JSONField(name = "updateTime", format = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private java.util.Date updateTime;

    @ApiModelProperty("分类id")
    @JSONField(name = "categoryId", serializeUsing = ToStringSerializer.class)
    private java.lang.Long categoryId;

    @ApiModelProperty("分类")
    @JSONField(name = "category")
    private org.aristotle.demo.model.vo.CategoryVO category;

}
